/*
 * Solver.h
 *
 *  Created on: 17 déc. 2011
 *      Author: marc
 */

#ifndef SOLVER_H_
#define SOLVER_H_

#include <vector>
#include <string>

struct T_Operation
{
        int iA;
        int iB;
        char cOperation;
};

struct T_Solution
{
        int iMaxValue;
        std::vector<T_Operation> vecSolution;
};

class Solver
{
    public:
        Solver();
        virtual ~Solver();

    public:
        static bool findFirstPossibleSolution(const std::vector<int>& _vecInput, const int _iResult, T_Solution* _ptSolution);
        static void findAllSolution();
        static T_Operation createOperation(const int _iA, const int _iB, const char _cOperation);
        static int getResultForOperation(const T_Operation& _operation);
        static std::string getStringForOperation(const T_Operation& _operation);
        static std::string getStringForOperationWithoutResult(const T_Operation& _operation);

    private:
};

#endif /* SOLVER_H_ */
